package org.sy.lab.多线程基础._1_管理._4_异常捕获.线程组uncaughtException;

public class MyThreadGroup extends ThreadGroup {

	public MyThreadGroup(String name) {
		super(name);
	}
	
	@Override
	public void uncaughtException(Thread t, Throwable e) {
		System.out.println("捕获到线程组的异常，异常线程：" + t.getName());
		e.printStackTrace();
		interrupt();
	}
}
